#include <iostream>
using namespace std;

/** 
 *  蔡勒公式
 *  w = ([c/4] - 2c + y + [y/4] + [13(m + 1) / 5] + d - 1) % 7
 *  其中 w为星期 c为年份前两位 y为年份后两位 m为月份, 但是某年的1, 2月要看做上一年的13, 14月 d为日 []为取整
*/

//蔡勒公式
int dayToWeek(int year, int month, int day) //根据哪天推算星期几
{
    if (month == 1 || month == 2)
    {
        month += 12;
        year -= 1;
    }
    int headYear = year / 100;
    int tailYear = year % 100;
    int week = headYear / 4 - 2 * headYear + tailYear / 4 + tailYear + (13 * (month + 1)) / 5 + day - 1;
    week = (week % 7 + 7) % 7;
    if (week == 0)
        return 7;
    else
        return week;
}
int weekToDay(int year, int month, int count, int Pweek) //根据星期几推算哪天
{
    int week = dayToWeek(year, month, 1); //计算该月1日为星期几
    int day = 1 + (count - 1) * 7 + (7 + Pweek - week) % 7;
    return day;
}

//元旦
void newYear(int year)
{
    printf("%d-01-01\n", year);
}
//马丁·路德·金纪念日
void maDingLuDeJin(int year)
{
    printf("%d-01-%02d\n", year, weekToDay(year, 1, 3, 1));
}
//总统日
void zongTongRi(int year)
{
    printf("%d-02-%02d\n", year, weekToDay(year, 2, 3, 1));
}
//阵亡将士纪念日
void zhenWangJiangShiJiNianRi(int year)
{
    int week = dayToWeek(year, 6, 1);
    int day = 31 - ((week == 1) ? 6 : week - 2);
    printf("%d-05-%02d\n", year, day);
}
//国庆节
void guoQing(int year)
{
    printf("%d-07-04\n", year);
}
//劳动节
void laoDongJie(int year)
{
    printf("%d-09-%02d\n", year, weekToDay(year, 9, 1, 1));
}
//感恩节
void ganEnJie(int year)
{
    printf("%d-11-%02d\n", year, weekToDay(year, 11, 4, 4));
}
//圣诞节
void shengDanJie(int year)
{
    printf("%d-12-25\n", year);
}
//美国节日
void holidayOfUsa(int year)
{
    newYear(year);
    maDingLuDeJin(year);
    zongTongRi(year);
    zhenWangJiangShiJiNianRi(year);
    guoQing(year);
    laoDongJie(year);
    ganEnJie(year);
    shengDanJie(year);
    cout << endl;
}

int main()
{
    int year;
    while (cin >> year)
    {
        holidayOfUsa(year);
    }
    return 0;
}
